public class Player implements Observer {
    String name;
    @Override
    public String getName() {
        return name;
    }

    @Override
    public void setName(String name) {
        this.name = name;
    }

    @Override
    public void help() {
        System.out.println("Player " + name + "提供帮助");
    }

    @Override
    public void beAttacked(AllyControlCenter acc) {
        System.out.println(name+"受到攻击！");
        acc.notifyObserver(name);
    }

}
